package com.corpgovernment.costcenter.service;

import com.corpgovernment.api.costcenter.model.CostCenterParamValidateRequest;
import com.corpgovernment.api.costcenter.model.CostCenterParamValidateResponse;
import com.corpgovernment.api.costcenter.model.GetDepartmentsRequest;
import com.corpgovernment.api.organization.dto.request.ProjectInfoDto;
import com.corpgovernment.api.organization.model.project.request.CollectProjectInfoRequest;
import com.corpgovernment.api.organization.model.project.request.GetProjectInfoRequest;
import com.corpgovernment.api.organization.model.project.response.ProjectInfoResponse;
import com.corpgovernment.api.organization.vo.GetOrgTreeRsp;
import com.corpgovernment.costcenter.entity.db.MbOrgProjectInfo;
import com.corpgovernment.costcenter.vo.*;
import org.springframework.web.multipart.MultipartFile;

import javax.servlet.http.HttpServletResponse;
import java.util.Collection;
import java.util.List;
import java.util.Map;

public interface IProjectInfoService {

    Integer insert(ProjectInfoVo request);

    boolean delete(ProjectInfoDelVo request);

    ProjectInfoPageResponseVo select(ProjectInfoPageVo request);

    List<GetOrgTreeRsp> getOrgTree(GetDepartmentsRequest request);

    boolean update(ProjectInfoVo request);

    List<String> selectCostAndProjectOrgId();

    ProjectInfoResponse selectPage(GetProjectInfoRequest request) throws Exception;

    String syncProjectInfoExcel(MultipartFile file, ProjectInfoExcelVo requestVo);

    ProjectUploadInfoPageResponseVo selectUploadInfoPage(ProjectUploadInfoPageRequestVo requestVo);

    ProjectUploadInfoPageResponseVo selectUploadDetailInfoPage(ProjectUploadInfoPageRequestVo requestVo);

    void downloadUploadInfo(String taskNo, HttpServletResponse response);

    Boolean collectProjectInfo(CollectProjectInfoRequest request);

    void downloadProjectInfo(String companyId, HttpServletResponse response);

    List<MbOrgProjectInfo> selectProjectInfoByCompanyId(String companyId);

    List<MbOrgProjectInfo> selectProjectInfoByCompanyIds(List<Integer> companyId);

    List<ProjectInfoDto> selectProject(CostCenterParamValidateRequest request);

    List<ProjectInfoDto> getProjectInfoByOrgId(String orgId);

    List<ProjectInfoDto> listProjectInfoByOrgId(List<String> orgIdList);

    List<ProjectInfoDto> getProjectByProjectCode(List<String> projectCodes);

    ProjectInfoPageResponseVo queryProjectNameCode(ProjectInfoPageVo request);

    CostCenterParamValidateResponse getProject(CostCenterParamValidateRequest request);

    List<MbOrgProjectInfo> listByProjectCode(Collection<String> projectCodes);

    Map<String, List<ProjectInfoDto>> listProjectInfoByOrgIdNew(List<String> orgIdList);
}
